﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Runtime.Serialization;
using System.ServiceModel;
using System.Text;
using LotteryWCF.AdminConstract;
namespace LotteryWCF
{
    // 注意: 使用“重构”菜单上的“重命名”命令，可以同时更改代码和配置文件中的接口名“ILotteryAdmin”。
    [ServiceContract]
    public interface ILotteryAdmin
    {
        [OperationContract]
        bool FrozenUser(int isActive, string userId);

        [OperationContract]
        List<MemberList> GetLowerMemberByUID(Int64 ID);

        [OperationContract]
        List<LotteryInfo> GetLotteryInfo(string lotteryName, string isEnable, string Orientation);

        [OperationContract]
        List<PlayTypeInfo> GetPlayTypeInfo(string lotteryName, string isEnable, string Orientation, string playTypeName);

        [OperationContract]
        List<PlayTypeInfo> GetPlayTypeInfoByLotteryId(Int64 lotteryId);

        [OperationContract]
        List<PlayTypeRadioInfo> GetPlayRadioInfo(string lotteryName, string isEnable, string Orientation, string playTypeName, string playRadioName);

        [OperationContract]
        List<PlayTypeRadioInfo> GetPlayRadioInfoByPlayTyPeId(Int64 playTypeId);

        [OperationContract]
        bool UpdateLotteryIsEnable(LotteryInfo isEnable);

        [OperationContract]
        bool UpdateLotteryIsOpen(LotteryInfo isOpen);

        [OperationContract]
        bool UpdateLotteryName(LotteryInfo lottery);

        [OperationContract]
        bool UpdatePlayTypeIsEnable(PlayTypeInfo isEnable);

        [OperationContract]
        bool UpdatePlayTypeName(PlayTypeInfo lottery);

        [OperationContract]
        bool UpdatePlayRadioIsEnable(PlayTypeRadioInfo isEnable);

        [OperationContract]
        bool UpdatePlayRadioName(PlayTypeRadioInfo lottery);

        [OperationContract]
        List<LotteryInfo> GetAllLotteryInfo();

        [OperationContract]
        List<PlayTypeInfo> GetAllPlayTypeInfo();

        [OperationContract]
        List<PlayTypeRadioInfo> GetPlayTypeRadioForBonus(string lotteryId, string playTypeName, Int64 orientation, string playTypeRadioName);

        [OperationContract]
        List<Odds> GetDefaultOdds(string lotteryId, string playTypeName, string playRadioName);

        [OperationContract]
        List<Odds> GetCurrentOdds(string lotteryId, string playTypeName, string playRadioName);

        [OperationContract]
        bool UpdatePlayTypeRadioBonus(PlayTypeRadioInfo info);

        [OperationContract]
        bool UpdateDefaultOdds(Odds info);

        [OperationContract]
        bool UpdateCurrentOdds(Odds info);

        [OperationContract]
        List<BetRecord> GetBetRecord(Int64 playTypeId, Int64 recordId, Int64 lotteryId, string isPj, string userid, string winorlose, string dateStart, string dateEnd);

        [OperationContract]
        List<ProfitReport> GetAdminProfitReport(DateTime start, DateTime end);

        [OperationContract]
        List<ProfitDetail> GetAdminProfitDetail(string type, DateTime start, DateTime end);

        [OperationContract]
        List<ProfitReport> GetProfitReport(string userid, DateTime start, DateTime end);

        [OperationContract]
        List<ProfitDetail> GetProfitDetail(string userid, string type, DateTime start, DateTime end);

        [OperationContract]
        List<CarrierBankInfo> GetCarrierBank();

        [OperationContract]
        bool ChangeBankEnable(CarrierBankInfo bankInfo);

        [OperationContract]
        bool UpdateBank(CarrierBankInfo bankInfo);

        [OperationContract]
        List<News> GetNews(int type, int isEnable);

        [OperationContract]
        bool UpdateNews(News news);

        [OperationContract]
        bool ChangeNewEnable(News news);

        [OperationContract]
        string ValidateLogin(string userId, string pwd);

        [OperationContract]
        bool ChangeAdminPwd(string userId, string pwd);

        #region  xjw
        [OperationContract]
        bool AddMember(User user);

        [OperationContract]
        bool DeleteMember(MemberList info);

        [OperationContract]
        Dictionary<string, string> GetOverAllCfg();

        [OperationContract]
        List<MemberList> GetMemberListData(string UserID, int IsOnline, int IsActive, int RoleID, string UID);

        [OperationContract]
        int GetMemberListDataCount(string UserID, int IsOnline, int IsActive, int RoleID, int PageSize);

        [OperationContract]
        MemberInfo GetMemberInfoByUID(string UserID);

        [OperationContract]
        List<MemberBankInfo> GetMemberBankInfoByUID(string UserID);

        [OperationContract]
        Capital GetCapitalByUID(string UserID);

        [OperationContract]
        bool UpdateMemberInfoByUID(MemberInfo mInfo, string UserID);

        [OperationContract]
        bool UpdateMemberBankInfoByUID(MemberBankInfo MBInfo, string UserID);

        [OperationContract]
        bool UpdateCapitalByUID(Capital capitalInfo, string UserID);

        [OperationContract]
        List<MemberList> GetMemberListByID(string ID, string UserID);

        [OperationContract]
        bool MoneyIn(string UID, double Money);

        [OperationContract]
        List<MoneyInList> GetMoneyInListByUID(string UID);

        [OperationContract]
        List<MoneyOutList> GetMoneyOutList();

        [OperationContract]
        List<MoneyOutList> GetMoneyOutListBy(string UID, DateTime dtFrom, DateTime dtTo, int Status);

        [OperationContract]
        bool DealMoneyOut(MoneyOutList info);

        [OperationContract]
        OverallConfig GetGlobalConfig();

        [OperationContract]
        bool SaveGloablConfig(Dictionary<int, string> values);

        [OperationContract]
        List<LotteryNumsInfo> GetLotteryNumsInfoList(string IssueNums, DateTime dtFrom, DateTime dtTo, int LotteryType);

        [OperationContract]
        string GetCurrenIssuNo(string lotteryId);

        [OperationContract]
        LotteryNumsInfo SetLotteryNumsInfo(int type);

        [OperationContract]
        int UpdateLotteryNums(LotteryNumsInfo info);
        #endregion 

        [OperationContract]
        List<Log> GetBgLogData(string userName, string titile, DateTime dtFrom, DateTime dtTo);

        [OperationContract]
        List<Log> GetFgLogData(string userName, DateTime dtFrom, DateTime dtTo);

        [OperationContract]
        bool AddLottery(LotteryInfo info);

        [OperationContract]
        bool ManualPaijiang(LotteryType type,string issueNo);

        [OperationContract]
        bool DeleteNews(News news);

        [OperationContract]
        bool DeletePlatformBank(CarrierBankInfo info);

        [OperationContract]
        bool DeleteBetRecord(BetRecord record);
    }
}
